<?php
    require('/connect.php');
    $query1="SELECT *
        FROM Buildings;";
    $result1=mysql_query($query);
    while($row=mysql_fetch_array($result1)){
        for($i=0;$i<$row['floors'];$i=$i+1){
            echo "<option value=$i>$i</option>";
        }
    }
    mysql_close($con);
?>
